<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');   

    require_once ($application_folder."/libraries/MY_Controller.php"); 
    class Navigator extends MY_Controller {

        var $data = array();

        function __construct()
        {
            parent::__construct();
        }

        function index() { show_404(); }        

        function core_site($page=NULL,$data=NULL, $sub=NULL,$upsub=NULL){

            if ($data!=NULL){
                $this->data = array_merge((array)$this->data, (array)$data);   
            }



            $this->data['page'] = $page;
            $this->data['sub'] = $sub;
            $this->data['upsub'] = $upsub;
            /*$this->data['lang'] = $this->lang_ses->getlang();*/
            $this->data['path'] = base_url().'assets/';    
            $this->data['url'] = base_url();    
            $this->data['info_sis_url'] = 'http://www.informacionisistem.com/rentacar/assets/cars/';
            $this->data['info_sis_url'] = 'http://localhost/infosis/rentacar/assets/cars/';

            $url="";

            if(($sub=='')&&($upsub=='')){ 

                $url = $page;
                //$this->asset->flag('page');

            }else if($upsub==''){ 

                    $url = $page.'/'.$sub;
                    //$this->asset->flag('sub');

                }else{

                    $url = $page.'/'.$sub.'/'.$upsub;
                    //$this->asset->flag('upsub');

            }

            //$this->asset->layoutflag('site');

            //$this->asset->initialze_assets($page, $sub, $upsub);

            if(!isset($this->data['title'])){
                $this->data['title'] = 'No title';
            }

            /*$this->data['language'] = $language = $this->lang->lng_lines();*/

            $this->layout->view('site/'.$url, $this->data);


        }


    }
?>
